Storing Debug Recording Files on Device

When debug recording is active, the device duplicates all messages that are sent and received by it, and then can write them to a file that can be stored locally on the hard disk of the server platform on which the device is installed. This feature is applicable only to Logging Filter rules (in the Logging Filters table) whose 'Log Destination' parameter is configured to Local Destination and 'Log Type' to any value except CDR or SIP Ladder.

The debugging files are stored on the device in the /debug-recording folder. New debug recordings are stored in a file called "Current". Once this file meets a user-defined criteria—maximum file size or rotation period (whichever is first fulfilled)—a file is created. The file is compressed into a GZIP file and assigned the name using the following format: DR_<YYYY>_<Month>_<DD>_<HH.MM.SS>_<SEQ>, where SEQ is a unique serial number.

The device can store debug recording files locally and at the same time, send the debug recording to an external debug recording server.
For Logging Filter rules whose 'Log Destination' parameter is configured to Local Storage and 'Log Type' to CDR, these recordings are added to the CDRs files (not the debug recording files). For more information, see Storing CDRs Locally on the Device.
To configure local Debug Recording storage:
1. Open the Logging Filters table (see Configuring Log Filter Rules), and then enable local storage for debug recording by configuring a log filtering rule with the following settings:
'Filter Type': You can configure this parameter to any value.
'Value': If 'Filter Type' is configured to any value except Any, then it must be configured; otherwise, leave it blank.
'Log Destination': Local Storage.
'Log Type': Configure this parameter to any value, except CDR or SIP Ladder.
'Mode': Enable.
2. Open the Debug Recording page (Troubleshoot tab > Troubleshoot menu > Logging folder > Debug Recording).

3. From the 'Local Storage' drop-down list, select Enable to enable local storage of debug recording files.
4. From the 'Recording' drop-down list, select Enable to start debug recording file creation and local storage.
5. In the 'File Size' field, enter the maximum size of the debug recording file. When the Current file reaches this size, the device creates a file. However, if the 'Rotation Period' parameter is reached before the file has reached this maximum size, the file is created.
6. In the 'Number of Files' field, enter the maximum number of debug recording files that can be stored. Depending on the configuration of the 'File Mode' parameter, if this maximum is reached, any new file replaces the oldest file (i.e., FIFO) or the device stops debug recording.
7. From the 'File Mode' drop-down list, select
Cyclic: When the number of maximum files has been reached, the device continues debug recording and the new file overwrites the oldest file.
Non-Cyclic: When the number of maximum files has been reached, the device stops debug recording.
8. In the 'Rotation Period' field, enter the periodic duration (in minutes) of how often a debug recording file is created from the Current file (even if empty). For example, if configured to 60, a file is created every hour (or before if the maximum size has been reached).
9. Click Apply; the device calculates the required storage size for the debug recording files (number of files x file size):
If the device has sufficient storage size, it accepts your configuration and reserves disk space for the debug recording files.
If there is insufficient storage size, the device displays an error message to indicate this. In this scenario, configure the 'Local Storage' parameter to Disable.

The status of the local file storage is displayed in the read-only 'Operational Status' field:

"On" indicates that debug recording is active (recording)
"Off" indicates that debug recording is not active
If you disable local storage (i.e., 'Local Storage' parameter is configured to Disable), the device deletes all stored debug recording files. In addition, it no longer reserves storage space previously allocated for debug recording files.
Even if the device restarts or powers off, the locally stored debug recording files are preserved.
If local storage was enabled and is active and you later modify at least one of the following fields -- 'File Size', 'Number of Files', 'File Mode' and 'Rotation Period' -- before the device applies your new settings, it checks again if it has sufficient storage size. If it does, it accepts your settings; otherwise, they revert to their previous settings. In addition, when modifying these parameters, the device may delete all debug recording files.
When the device operates in High-Availability (HA) mode, active and redundant devices maintain their own locally stored debug recording files. In other words, upon an HA switchover the stored debug recording files on the active device are not copied to the redundant device (which becomes the new active device).
When the device operates in HA mode, you can view the locally stored debug recording files on the redundant device without performing a switchover. This is done by accessing the redundant device from the active device through SSH (or SFTP), as described in Accessing Files on Redundant Device from Active through SSH.
For a detailed description of each parameter, see Syslog, CDR and Debug Parameters.